package com.example.high_slope_electronic_sand_table.environment.dto;

import com.example.high_slope_electronic_sand_table.common.config.CustomFloatSerializer;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * 环境监测设备
 */
@Data
@Schema(description = "环境监测设备")
public class EnvironmentMonitorDTO {
    @Schema(description = "设备ID")
    private String deviceId; // 设备ID
    @Schema(description = "温度")
    @JsonSerialize(using = CustomFloatSerializer.class)
    private Float temperature; // 温度
    @Schema(description = "温度告警等级")
    private Integer temperatureWarningLevel; // 温度告警等级
    @Schema(description = "湿度")
    @JsonSerialize(using = CustomFloatSerializer.class)
    private Float humidity; // 湿度
    @Schema(description = "湿度告警等级")
    private Integer humidityWarningLevel; // 湿度告警等级
    @Schema(description = "风速")
    @JsonSerialize(using = CustomFloatSerializer.class)
    private Float speed; // 风速
    @Schema(description = "风速告警等级")
    private Integer speedWarningLevel; // 风速告警等级
    @Schema(description = "上报时间")
    private String datetime;// 上报时间

}
